﻿namespace Liger.Web.UI
{
    using System;
    using System.Collections.Generic;
    using System.Linq;
    using System.Text;

    public class GridEditingSettingsBuilder
    {
        private readonly GridEditingSettings editing;
        public GridEditingSettingsBuilder(GridEditingSettings editing)
        {
            this.editing = editing;
        }
        /// <summary>
        /// 是否启用编辑
        /// </summary>
        /// <param name="value"></param>
        /// <returns></returns>
        public GridEditingSettingsBuilder Enabled(bool value)
        {
            this.editing.Enabled = value;
            return this;
        } 
         
        /// <summary>
        /// 是否双击的时候才编辑
        /// </summary>
        public GridEditingSettingsBuilder DblClickToEdit(bool value)
        {
            this.editing.DblClickToEdit = value;
            return this;
        } 
    }
}
